package com.kgc.xsProvider.service;

import com.kgc.basic.util.ResponseMsg;
import com.kgc.xs.pojo.SalesInvoice;
import com.kgc.xs.pojo.SalesOutDetail;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Map;

public interface SalesInvoiceService {
    //测试插入销售发票主表数据
    ResponseMsg insertMainSalesInvoice(SalesInvoice salesInvoice);



    ResponseMsg selectSalesInvoiceByPage(Map<String, Object> map);

    //根据客户（cid）查询对应销售出库单
    ResponseMsg selectSalesOutByCid(int customerId);

    //根据销售出库单单据编号查询该单据的明细
    ResponseMsg selectSalesOutByCode(@RequestParam("code") String code);

    ResponseMsg insertSalesInvoice(Map<String, Object> map);

    ResponseMsg deleteSalesInvoice(@RequestParam("id") int id);

    //根据单据编号查询销售发票（回显）
    ResponseMsg selectSalesInvoiceByCode(@RequestParam("code") String code);

    //回显（明细）
    ResponseMsg selectSalesInvoiceDetailByCode(@RequestParam("invoiceCode") String invoiceCode);

    //根据单据编号删除主表数据
    ResponseMsg deleteSalesInvoiceByCode(String code);

    //根据关联的单据编号删除明细表数据
    ResponseMsg deleteSalesDetailsByCode(String code);

    //
    ResponseMsg getOutStoreList(Map<String,Object> map);
}
